<template>
	<view class="container">
		<cu-header bgColor="bg-gradual-blue" :isBack="true">
			<block slot="content" class="page-name">确认订单</block>
		</cu-header>
		<view class="contents">
			<view class="bg-gradual-blue padding-sm" @click="onSeletAddress">
				<view class="bg-white  radius flex justify-center align-center padding-sm">
					<view class="cuIcon-location size-84 text-red"></view>
					<view class="margin-left-sm">
						<view>
							<text class="text-black text-size-32 text-blod">孙秋龙</text>
							<text class="text-gray text-size-16 margin-left-sm">18716643045</text>
						</view>
						<view>
							湖南省岳麓区丰顺路卫生院13东123号
						</view>
					</view>
					<view class="cuIcon-right size-36 margin-left-sm"></view>
				</view>
			</view>
			<view class="cu-card article">
				<view class="cu-item shadow">
					<view class="title flex justify-between">
						<view class="align-center">
							<text class="cuIcon-shop size-44"></text>
							<text class="text-size-32 margin-left-sm">很爱旗舰店</text>
							<text class="cuIcon-right size-36"></text>
						</view>
						<view></view>
					</view>
					<cu-list-goods :datas="goods"></cu-list-goods>
					<view class="flex justify-end">
						<button @click="onSelectAfterSale" class="cu-btn round lines-gray margin-right-sm">退款</button>
					</view>
					<view class="flex justify-between padding-lr padding-top-xs padding-bottom-xs">
						<view>配送方式：普通配送</view>
						<view>快递免邮</view>
					</view>
					<view class="flex justify-start padding-lr padding-top-xs padding-bottom-xs">
						<view>运费险</view>
						<view>
							<view>未选择</view>
							<view>请关注保险公司信息，并阅读《保险条款和重要说明》,本模块有蚂蚁保障代理有限公司管理</view>
						</view>
					</view>
					<view class="flex justify-between padding-lr padding-top-xs padding-bottom-xs">
						<view>开具发票</view>
						<view>本次不开具发票</view>
					</view>
					<view class="flex justify-between padding-lr padding-top-xs padding-bottom-xs">
						<view>订单备注</view>
						<view>选填,请先和商家协商一致</view>
					</view>
				</view>
				
			</view>
			
		</view>
		<view class="fixed foot flex flex-wrap padding">
			<button @click="onCommit"
				class="cu-btn round bg-orange flex-sub">提交订单 ￥38.00</button>
		</view>
	</view>
</template>

<script>
	import {
		mapState,
		mapMutations
	} from 'vuex';
	import cuListGoods from '@/components/diy/list/cu-list-goods.vue'
	import cuGridMedia from '@/components/diy/list/cu-grid-media.vue';
	export default {
		computed: {
			...mapState(['hasLogin', 'forcedLogin', 'userinfo'])
		},
		components: {
			cuListGoods,
			cuGridMedia
		},
		data() {
			return {
				goods: [{
						name: "时尚运动鞋",
						price: 150,
						number: 2,
						image: 'https://ossweb-img.qq.com/images/lol/web201310/skin/big10006.jpg'
					},
					{
						name: "运动套装",
						price: 280,
						number: 2,
						image: 'https://ossweb-img.qq.com/images/lol/web201310/skin/big10006.jpg'
					}
				]
				
			};
		},
		/**
		 * 用户点击右上角分享
		 */
		onShareAppMessage: function(res) {
			if (res.from === 'button') {
				// 来自页面内分享按钮
				console.log(res.target);
			}
			return this.shareinfo;
		},
		onLoad() {},
		onShow() {

		},
		methods: {
			...mapMutations([]),
			onSeletAddress: function() {
				this.$util.redirectTo('/pages/shop/address/index')

			},
			onCommit:function(e){
				this.$util.redirectTo('/pages/shop/order/paySucceed')
			}

		}
	};
</script>

<style scoped></style>
